package com.pignest.hotel.beans;

import java.util.Date;

import com.pignest.hotel.beans.global.BaseBean;
import com.pignest.hotel.definition.OpenRoomType;

public class ProtocolList extends BaseBean {

	/**
	 * 协议单位消费的记录清单
	 */
	private static final long serialVersionUID = -7625194872365611948L;

	public static final int HANGUP_UNCHECK = 0;	//挂账未结账
	public static final int HANGUP_CHECK = 1;	//挂账已结账
	/**协议单位*/
    private ProtocolUnit protocolUnit;
    /**入住信息*/
    private Living living;
    /**入住客人姓名*/
    private String name;
    /**房间号*/
    private String roomName;
    /**开房方式*/
    private String openName;
    /**入住时间*/
    private Date livingTime;
    /**离开时间*/
    private Date leaveTime;
    /**协议单价*/
    private int adjustPrice;
    /**金额*/
    private int price;
    /**状态0未结账、1已结账*/
    private int state;
    
    private Date opTime;
    
    private String opUser;
    
    private Date checkTime;
    public ProtocolList(){
    	
    }
	public ProtocolUnit getProtocolUnit() {
		return protocolUnit;
	}

	public void setProtocolUnit(ProtocolUnit protocolUnit) {
		this.protocolUnit = protocolUnit;
	}

	public Living getLiving() {
		return living;
	}

	public void setLiving(Living living) {
		this.living = living;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getRoomName() {
		return roomName;
	}

	public void setRoomName(String roomName) {
		this.roomName = roomName;
	}

	public String getOpenName() {
		return openName;
	}

	public void setOpenName(String openName) {
		this.openName = openName;
	}

	public Date getLivingTime() {
		return livingTime;
	}

	public void setLivingTime(Date livingTime) {
		this.livingTime = livingTime;
	}

	public Date getLeaveTime() {
		return leaveTime;
	}

	public void setLeaveTime(Date leaveTime) {
		this.leaveTime = leaveTime;
	}

	public int getPrice() {
		return price;
	}

	public void setPrice(int price) {
		this.price = price;
	}

	public int getState() {
		return state;
	}

	public void setState(int state) {
		this.state = state;
	}
	
    public Date getOpTime() {
		return opTime;
	}
	public void setOpTime(Date opTime) {
		this.opTime = opTime;
	}
	public String getOpUser() {
		return opUser;
	}
	public void setOpUser(String opUser) {
		this.opUser = opUser;
	}
	
	public Date getCheckTime() {
		return checkTime;
	}
	public void setCheckTime(Date checkTime) {
		this.checkTime = checkTime;
	}
	
	public int getAdjustPrice() {
		return adjustPrice;
	}
	public void setAdjustPrice(int adjustPrice) {
		this.adjustPrice = adjustPrice;
	}
	public String getState2()
    {
    	switch (state) {
		case 0:
			return "挂账未结";
		case 1:
			return "挂账已结";
		default:
			break;
		}
		return "无效状态";
    }
    public String getOpenName2()
    {
    	return OpenRoomType.valueof(openName).getDisplayName();
    }
}
